<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<!--

 @(#)package.html
 
 $Id$
 
 Created on Apr 4, 2005

 Copyright (C) 2005 Internet Archive.

 This file is part of the Heritrix web crawler (crawler.archive.org).

 Licensed to the Internet Archive (IA) by one or more individual 
 contributors. 
 
 The IA licenses this file to You under the Apache License, Version 2.0
 (the "License"); you may not use this file except in compliance with
 the License.  You may obtain a copy of the License at
 
     http://www.apache.org/licenses/LICENSE-2.0
 
 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.
-->
</head>
<body bgcolor="white">
Provides classes for a simple decision rules framework.

<p>Each 'step' in a decision rule set which can
affect an objects ultimate fate is called a <code>DecideRule</code>.
Each DecideRule renders a decision (possibly neutral) on the
passed objects fate.</p>

<p>Possible decisions are:
<ul>
  <li>ACCEPT means the object is ruled-in for further processing</li>
  <li>REJECT means the object is ruled-out for further processing</li>
  <li>PASS means this particular DecideRule has no opinion</li>
</ul>
</p>

<p>As previously outlined, each DecideRule is applied in turn;
the last one to express a non-PASS preference wins.</p>

<p>For example, if the rules are:
<ul><li>AcceptDecideRule -- ACCEPTs all (establishing a default)</li>
<li>TooManyHopsDecideRule(max-hops=3) -- REJECTS all with
      hopsPath.length()>3, PASSes otherwise</li>
<li>PrerequisiteAcceptDecideRule -- ACCEPTs any with 'P' as
      last hop, PASSes otherwise (this allows 'LLL's which
      need a 'LLLP' prerequisite a chance to complete)</li>
</ul>
Then, you have a crawl that will go 3 hops (of any type)
from the seeds, with a special affordance to get prerequisites
 of 3-hop items (which may be 4 "hops" out)</p>
   
<p>To allow this style of decision processing to be plugged into the
   existing Filter and Scope slots:
<ul><li>There's a DecidingFilter which takes an (ordered) map of
     DecideRules</li>
<li>There's a DecidingScope which takes the same</li>
</ul>
</p>

<p>See <a href="http://crawler.archive.org/cgi-bin/wiki.pl?NewScopingModel">NewScopingModel</a>
for background.</p>
</body>
</html>
